﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

namespace Stationery.UC
{
    public partial class UC_Banner : System.Web.UI.UserControl
    {
        protected void Page_Load(object sender, EventArgs e)
        {

        }

        protected void ASPxButtonSave_Click(object sender, EventArgs e)
        {
            if (ASPxUploadControl1.HasFile)
            {
                string strFileName = Server.MapPath("Image\\Banner\\" + ASPxComboBox1.Value.ToString());

                ASPxUploadControl1.SaveAs(strFileName,true);

                ScriptManager.RegisterStartupScript(this, this.GetType(), "message", "alert('Thành công');location.href = 'Admin.aspx?id=banner';", true);
            }
        }
    }
}